<template>
    <div id="con">
        <div class="title">
            <!--            <i v-on:click="this.$router.go(-1);" class="fa-solid fa-chevron-left title-1" style="font-size: 30px;"><</i>-->
            <div class="title-0">
                登录页面
            </div>
        </div>
        <div class="Main">
            <!--            <div class="Input1">-->
            <!--                <div class="Img1">-->

            <!--                </div>-->
            <!--                <input type="text" v-model="username" placeholder="账号">-->
            <!--            </div>-->
            <el-input
                    class="username_input"
                    v-model="username"
                    style="background-color:aliceblue "
                    type="text"
                    placeholder="账号"
            />
            <!--      <div class="Input2">-->
            <!--        <div class="Img2">-->
            <!--        </div>-->
            <!--        <input type="password" v-model="password"  show-password placeholder="密码">-->
            <!--        <div class="A">-->
            <!--          <i class="fa-regular fa-eye"></i>-->
            <!--        </div>-->
            <!--      </div>-->
            <el-input
                    class="password_input"
                    v-model="password"
                    style="background-color:aliceblue "
                    type="password"
                    placeholder="密码"
                    show-password
            />
            <div class="B">
                <input type="radio" name="" id="" :value="true" v-model="remember" v-on:click="this.remember=!remember">
                <div style="color: rgb(255, 0, 0);">
                    记住密码
                </div>
                <div class="C">
                    忘记密码?
                </div>
            </div>
            <div class="D">
                <input type="radio" name="" id="" :value="true" v-model="agreement"
                       v-on:click="this.agreement=!agreement">
                同意
                <div style="color:rgb(43, 170, 164);">《平台协议》</div>
                和
                <div style="color:rgb(43, 170, 164);">《隐私协议》</div>
            </div>
            <button class="E" type="button" @click="Login">
                登录
            </button>
            <div class="F">
                <div>
                    使用验证码注册
                </div>

                <div style="flex-grow: 1;text-align: right;" v-on:click="this.$router.push('/home')">
                    游客登录
                </div>
            </div>
        </div>
    </div>
</template>
<script>
export default {
    data() {
        return {
            remember: false,
            agreement: false,
            username: null,
            password: null,
            code: null,
        }
    },
    methods: {
        Login() {
            this.axios({
                method: 'put',
                url: 'http://localhost:8095/test/test'
            }).then(function (response) {
                console.log(response)
                console.log("Login");
                this.$router.push('/index');
            })

        }
    }
}
</script>
<style scoped>

.lef-1 {
    width: 100%;
    height: 100%;
    flex-grow: 1;
    background-color: rgb(28, 143, 104);

}

.title-0 {

    display: flex;
    justify-content: center;
    /* 水平居中 */
    align-items: center;
    /* 垂直居中 */
    flex-grow: 1;
}


#con {
    display: flex;
    /*默认横向排布*/
    align-items: center;
    flex-direction: column;
    /*width: %;*/
    height: 700PX;
    /*background-image: url("./assets/12.png");*/
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
}

.title {
    background-color: rgb(241, 239, 236);
    width: 472.81px;
    height: 50px;
    object-fit: cover;
    /* 调整图片适应方式，保持图片比例并覆盖整个容器 */
    /*position: absolute;*/
    /*top: 100px;*/
    /*left: 300px;*/
    z-index: 2;
    /* 将图片放置在底层，使其成为背景 */
    /*margin-top: 10px;*/
    /*margin-left: 10px;*/
    margin-top: 150px;
    display: flex;
    /*默认横向排布*/
    align-items: center;
    /* 垂直居中 */
}

.Main {
    background-color: rgb(241, 239, 236);
    width: 35vw;
    height: 50vh;
    display: flex;
    justify-content: center;
    /* 水平居中 */
    align-items: center;
    /* 垂直居中 */
    overflow: hidden;
    flex-direction: column;

    /*margin-top: 200px;*/
    padding-top: 10px;

    /*纵向排布*/

    ::-webkit-scrollbar {
        display: none;
    }

}

.F {
    width: 90%;
    height: 40px;
    display: flex;
    justify-content: center;
    /* 水平居中 */
    align-items: center;
    /* 垂直居中 */
    color: rgb(12, 170, 117);
}

.E {
    background-color: aquamarine;
    width: 90%;
    height: 40px;
//border: none; //outline: none;
}

.D {
    margin-top: 10px;
    width: 90%;
    height: 40px;
    display: flex;
    /*默认横向排布*/
    align-items: center;
    /* 垂直居中 */

}

.C {
    flex-grow: 1;
    text-align: right;
    margin-right: 3px;
    color: rgb(43, 170, 164);
}

.B {
    margin-top: 10px;
    width: 90%;
    height: 40px;
    display: flex;
    /*默认横向排布*/
    align-items: center;
    /* 垂直居中 */
}

.A {
    display: flex;
    justify-content: center;
    /* 水平居中 */
    align-items: center;
    /* 垂直居中 */

}

.Input2 input {
    width: 78%;
    border: none;
    outline: none;
    background-color: transparent;
}

.Img2 {
    display: flex;
    justify-content: center;
    /* 水平居中 */
    align-items: center;
    /* 垂直居中 */
    margin-left: 6px;
}

.Input1 input {
    width: 90%;
    border: none;
    outline: none;
    background-color: transparent;
}

.Img1 {
    display: flex;
    justify-content: center;
    /* 水平居中 */
    align-items: center;
    /* 垂直居中 */
    margin-left: 6px;
}

.Input1 {
    width: 90%;
    height: 50px;
    background-color: aliceblue;
    border-radius: 50px 50px 50px 50px;
    display: flex;
}

.Input2 {
    width: 90%;
    height: 50px;
    background-color: aliceblue;
    margin-top: 20px;
    border-radius: 50px 50px 50px 50px;
    display: flex;
}

.password_input {
    width: 90%;
    height: 50px;
    margin-top: 20px;
    background-color: aliceblue;

}

.username_input {
    width: 90%;
    height: 50px;
    margin-top: 20px;
    background-color: aliceblue;


}

</style>